﻿@{
    Layout = "~/Areas/CPP/Views/Shared/_MasterLayout.cshtml";
    var company = ViewBag.Company as CompanyInfo;
}
@{ Html.RenderAction("CLeft", "CCompany", new { cid = company.CompanyID });}
@model IList<AlbumInfo>
<div class="sy_center">
    <div class="pro_list2">
        <div class="pro_kuang">
            <div class="jjtiao">
                <div class="jjtext">相册列表</div>
            </div>
            <div class="jjkuang">
                @{
                    foreach (var album in Model)
                    {
                    <div class="product_item">
                        <div class="product_item_img">
                            <a href="@Url.Action("CPhotos", "CCompany")?cid=@company.CompanyID&aid=@album.AlbumId">
                                @if (album.Photos.Count == 0)
                                {
                                    <img alt="@album.AlbumName" src="/images/nothing.jpg" />
                                }
                                else
                                {
                                    <img alt="@album.AlbumName" src="@album.Photos[0].PhotoUrl" />
                                }
                            </a>
                        </div>
                        <div class="product_item_title">
                            <a href="@Url.Action("CPhotos", "CCompany")?cid=@company.CompanyID&aid=@album.AlbumId" 
                                title="@album.AlbumName">@album.AlbumName.Trim(11)</a>
                        </div>
                    </div>
                    }
                }

            </div>
        </div>
    </div>
</div>

